{\rtf1\mac\ansicpg10000\cocoartf102
{\fonttbl\f0\fswiss\fcharset77 Helvetica-Bold;\f1\fswiss\fcharset77 Helvetica;\f2\fnil\fcharset77 Monaco;
}
{\colortbl;\red255\green255\blue255;\red0\green0\blue191;\red191\green0\blue0;}
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f0\b\fs36 \cf0 Lorenz2DN		lorenz 2D chaotic generator\
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f1\b0\fs24 \cf0 \
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f0\b \cf0 Lorenz2DN.ar(minfreq, maxfreq, s, r, b, h, x0, y0, z0, mul, add)\
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f1\b0 \cf0 \
	
\f0\b freq
\f1\b0  - iteration frequency in Hertz\
	
\f0\b s, r, b 
\f1\b0 - equation variables\
	
\f0\b h
\f1\b0  - integration time step\
	
\f0\b x0
\f1\b0  - initial value of x\
	
\f0\b y0
\f1\b0  - initial value of y\
	
\f0\b z0
\f1\b0  - initial value of z\
	\
	x' = s(y - x)\
	y' = x(r - z) - y\
	z' = xy - bz
\f2\fs18 \
\

\f1\fs24 The time step amount 
\f0\b h 
\f1\b0 determines the rate at which the ODE is evaluated.  Higher values will increase the\
rate, but cause more instability.  This generator uses a different algorithm than the LorenzN/L/C ugen included with current distributions.  The resulting sound is somewhat different, and it also means that 
\f0\b h
\f1\b0  becomes unstable around 0.02.\
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f2\fs18 \cf0 \
\{ \cf2 Lorenz2DN\cf0 .ar(\cf2 11025, 44100) \cf0 \}.play(s);\
\
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural
\cf3 // randomly modulate params\cf0 \
(\
\{ \cf2 Lorenz2DN\cf0 .ar(\
	\cf2 11025\cf0 , 44100, \
	\cf2 LFNoise0\cf0 .kr(1, 2, 10), \
	\cf2 20,\cf0 \
	\cf2 LFNoise0\cf0 .kr(1, 1.5, 2),\
	0.02\
) * 0.2 \}.play(s);\
)\
\
\cf3 // as a frequency control\cf0 \
\{ \cf2 SinOsc\cf0 .ar(\cf2 Lorenz2DN\cf0 .ar(\cf2 40, 80, h:0.02\cf0 )*800+900)*0.4 \}.play(s);}